package com.onpositive.rest.model;

import java.util.ArrayList;

public class Body {
	
	private ArrayList<String> examples = new ArrayList<String>();

	public ArrayList<String> getExamples() {
		return examples;
	}

	public void addExample(String example) {
		this.examples.add(example);
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result
				+ ((examples == null) ? 0 : examples.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		Body other = (Body) obj;
		if (examples == null) {
			if (other.examples != null)
				return false;
		} else if (!examples.equals(other.examples))
			return false;
		return true;
	}

	public boolean isEmpty() {
		return examples.isEmpty();
	}
}
